package com.example.birdfriends.pojo.user;

import org.apache.ibatis.type.Alias;

import java.util.Date;

// 数据库用户数据
@Alias("user")
public class User {
    private Long id;  // id
    private String nickname;  // 昵称
    private String email;  // 邮箱
    private String phone;  // 手机号
    private String password;  // 密码
    private String place;    // 地址
    private Date birthday;  // 生日
    private String sex;  // 性别
    private String sign;  // 个性签名
    private String url;  // 头像url

    public void printUser() {
        System.out.println(
                "User{" +
                        "id=" + id +
                        ", nickname='" + nickname + '\'' +
                        ", email='" + email + '\'' +
                        ", phone='" + phone + '\'' +
                        ", password='" + password + '\'' +
                        ", place='" + place + '\'' +
                        ", birthday=" + birthday +
                        ", sex='" + sex + '\'' +
                        ", sign='" + sign + '\'' +
                        ", url='" + url + '\'' +
                        '}'
        );
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public void setPlace(String place) {
        this.place = place;
    }

    public String getPlace() {
        return place;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public void setSign(String sign) {
        this.sign = sign;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public Long getId() {
        return id;
    }

    public String getEmail() {
        return email;
    }

    public String getPhone() {
        return phone;
    }

    public String getPassword() {
        return password;
    }

    public Date getBirthday() {
        return birthday;
    }

    public String getSex() {
        return sex;
    }

    public String getSign() {
        return sign;
    }

    public String getUrl() {
        return url;
    }
}
